package jihe;

public class BookInfo {
    private int id;    //编号
    private String name;    //名称
    private int price;    //价格
    private String author;    //作者
    private String startTime;    //出版时间
    public BookInfo(int id,String name,int price,String author,String startTime)
    {
        this.id=id;
        this.name=name;
        this.price=price;
        this.author=author;
        this.startTime=startTime;
    }
    public String toString()
    {
        return this.id+"\t\t"+this.name+"\t\t"+this.price+"\t\t"+this.author+"\t\t"+this.startTime;
    }
    //上面5个属性的 setXxx() 和 getXxx() 方法
    public int getId()
    {
        return id;
    }
    public void setId(int id)
    {
        this.id=id;
    }
    public String getName()
    {
        return name;
    }
    public void setName(String name)
    {
        this.name=name;
    }
    public int getPrice()
    {
        return price;
    }
    public void setPrice(int price)
    {
        this.id=price;
    }
    public String getAuthor()
    {
        return author;
    }
    public void setAuthor(String author)
    {
        this.author=author;
    }
    public String getStartTime()
    {
        return startTime;
    }
    public void setStartTime(String startTime)
    {
        this.startTime=startTime;
    }
}
